# 计算固定资产折旧

yj=eval(input("原价"))
cz=eval(input("残值"))
n=eval(input("年限"))

jr = 2 / n
yt = 0
for i in range(n):
    if i < n-2:
        yj -= yt
        yt = yj * jr
        print("第{:2d}年折旧{:.2f}".format(i+1, yt))
    else:
        print("第{:2d}年折旧{:.2f}".format(i+1, (yj - cz - yt) / 2))
